/*
 * @Descripttion: 委外到货单
 * @version: V1.0
 * @Author: GaoWei
 * @Date: 2021-07-05 18:09:04
 * @LastEditors: GW
 * @LastEditTime: 2021-12-21 10:28:41
 */
import { axios } from '../../utils/request'

const api = {
    save: '/po/purchaseArrival/saveOrderForDelegate',
    examine: '/po/purchaseArrival/examine',
    delete: '/po/purchaseArrival/deleteByIdForDelegate',
    getcode: '/po/purchaseArrival/getCodeForDelegate',
}
/**
 * 保存委外到货单
 */
export function save (data) {
    return axios({
        url: api.save,
        method: "post",
        data: data
    })
}

/**
 * 审核委外到货单
 */
export function examine (data) {
    return axios({
        url: api.examine,
        method: "get",
        params: data
    })
}

/**
 * 删除委外到货单
 */
export function remove (data) {
    return axios({
        url: api.delete,
        method: "DELETE",
        params: data
    })
}

/**
 * 获取委外到货单单据编号
 */
export function getCode (data) {
    return axios({
        url: api.getcode,
        method: "get",
        params: data
    })
}

/**
 * 提交订单
 */
export function submitOrder (data) {
    return axios({
        url: '/po/purchaseArrival/submit',
        method: "get",
        params: data
    })
}
